<?php

use yii\helpers\Url;


$js = <<<JS
   $(function(){

        console.log('hello world');

    });
JS;

$this->registerJs($js, \yii\web\View::POS_END);

?>

<div class="row">
  <!--  
    <div class="col-md-12">
    	 <div class="panel panel-default">
    	 <div class="panel-heading">商户查找</div>
    	 <div class="panel-body">
        	<form class="form-inline" action="<?= Url::toRoute(['show']) ?>" method="post" target="_blank">
              <div class="form-group">
                <label for="business_id">商户id</label>
                <input type="text" class="form-control" id="business_id" placeholder="商户id" name="admin_id">
              </div>
              <div class="form-group">
                <label for="business_username">商户username</label>
                <input type="text" class="form-control" id="business_username" placeholder="商户username" name="admin_username">
              </div>
              <button type="submit" class="btn btn-default">查询</button>
            </form>
            </div>
        </div>
        </div>
        
        <div class="col-md-12">
    	 <div class="panel panel-info">
    	 <div class="panel-heading">用户查找</div>
    	 <div class="panel-body">
        	<form class="form-inline" action="<?= Url::toRoute(['member/show']) ?>" method="post" target="_blank">
              <div class="form-group">
                <label for="user_id">用户id</label>
                <input type="text" class="form-control" id="user_id" placeholder="用户id" name="user_id">
              </div>
              <div class="form-group">
                <label for="business_username">用户phone</label>
                <input type="text" class="form-control" id="user_phone" placeholder="用户phone" name="user_phone">
              </div>
              <button type="submit" class="btn btn-info">查询</button>
            </form>
            </div>
        </div>
    </div>
    -->
            <div class="col-md-12">
    	 <div class="panel panel-info">
    	 <div class="panel-heading">快捷查找</div>
    	 <div class="panel-body">
				<table class="table table-bordered">
                 <thead>
                 	<tr>
                 		<th>key</th>
                 		<th>id</th>
                 		<th>商户</th>
                 		<th>预警类型</th>
                 		<th>预警电话</th>
                 		<th>预警时间</th>
                 		<th>发送情况</th>
                 	</tr>
                 </thead>
                 
            	<tbody>
                <?php 
                    if ($list) :
                    foreach ($list as $key => $val) :
                ?>
               
                <tr>
                	<td><?= $key ?></td>
                	<td><?= $val['id']?></td>
                	<td><?= $val['admin_id']?></td>
                	<td><?= $val['sms_scene']?></td>
                	<td><?= $val['phone']?></td>
                	<td><?= date('Y-m-d H:i:s', $val['createtime'])?></td>
                	<td><?= $val['report_status']?></td>
                	
                	<!-- 
                	<td>
                		<button class="btn btn-primary btn-sm" type="button" data-id="">查看</button>
                		<button class="btn btn-success btn-sm" type="button" data-id="">充值记录</button>
                	</td>
                	-->
                </tr>
               
                <?php
                    endforeach;
                    endif;
                ?>
                
                  </tbody>
            </table>
            
            </div>
        </div>
    </div>
</div>